package com.kefu.admin.modules.tgqmdj.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.kefu.admin.modules.tgqmdj.mapper.ArticleMapper;
import com.kefu.admin.modules.tgqmdj.mapper.MenuMapper;
import com.kefu.admin.modules.tgqmdj.model.Article;
import com.kefu.admin.modules.tgqmdj.model.Menu;
import com.kefu.admin.modules.tgqmdj.model.TreeMenu;
import com.kefu.admin.modules.tgqmdj.model.TreeMenus;
import com.kefu.admin.modules.tgqmdj.service.ArticleService;
import com.kefu.admin.modules.tgqmdj.service.MenuService;

@Service
public class ArticleServiceImpl implements ArticleService {

	
	@Autowired
    private ArticleMapper articleMapper;
	
	@Override
	public List<TreeMenus> queryTreeMenus() {
		// TODO Auto-generated method stub
		return articleMapper.queryTreeMenus();
	}

	@Override
	public int insertText(Article article) {
		// TODO Auto-generated method stub
		return articleMapper.insertText(article);
	}

	@Override
	public List<Article> selectArticles(Article article) {
		// TODO Auto-generated method stub
		return articleMapper.selectArticles(article);
	}

	@Override
	public Article queryArticleByArticleId(Long articleid) {
		// TODO Auto-generated method stub
		return articleMapper.queryArticleByArticleId(articleid);
	}

	@Override
	public int updateArticle(Article article) {
		// TODO Auto-generated method stub
		return articleMapper.updateArticle(article);
	}

	@Override
	public int deleteArticle(Long articleId) {
		// TODO Auto-generated method stub
		return articleMapper.deleteArticle(articleId);
	}
	
	

}
